import {NgModule} from '@angular/core';
import {RouterModule, Routes} from '@angular/router';
import {OrderListComponent} from './order-list/order-list.component';
import {OrderDetailComponent} from './order-detail/order-detail.component';
import {AuthGuard} from '../shared/auth.guard';

const routes: Routes = [
  {path: '', component: OrderListComponent, canActivate: [AuthGuard]},
  {path: ':id', component: OrderDetailComponent, canActivate: [AuthGuard]}
]

@NgModule({
  imports: [
    RouterModule.forChild(routes)
  ]
})

export class OrdersRoutingModule {

}
